<%--05_mapkey.jsp--%>
<%@ page import="java.util.HashMap" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>05_mapkey</title>
</head>
<body>
    <%
        HashMap<String, Object> map = new HashMap<>();
        map.put("a", "ylaihui.com");
        map.put("a+a+b", "ylaihui.com");
        map.put("a.b.c", "ylaihui.com");

        request.setAttribute("key", map);
    %>

    ${ key } <br>
    ${ key.a } <br>
    <%--key中 有特殊字符时，会报错，需要使用 [] 获取key 的值--%>
    <%--${ key.a+a+b } <br>--%>
    ${ key["a+a+b"] } <br>
    ${ key['a.b.c'] } <br>
</body>
</html>
